<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>

<!Doctype html>
<html lang="en" class="fullscreen-bg">

<head>
    <title>Login | Jfinal-cms</title>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <!-- COMPONENTS CSS -->
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/bootstrap.min.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/components/font-awesome/css/font-awesome.min.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/components/linearicons/style.css">
    <!-- MAIN CSS -->
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/main.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/captcha.css">
    <!-- GOOGLE FONTS -->
    <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700" rel="stylesheet">
    <!-- ICONS -->
    <link rel="apple-touch-icon" sizes="76x76" href="${pageContext.request.contextPath}/assets/img/apple-icon.png">
    <link rel="icon" type="image/png" sizes="96x96" href="${pageContext.request.contextPath}/assets/img/favicon.png">
</head>

<body>
<!-- WRAPPER -->
<div id="wrapper">
    <div class="vertical-align-wrap">
        <div class="vertical-align-middle">
            <div class="auth-box ">
                <div class="left">
                    <div class="content">
                        <div class="header">
                            <div class="logo text-center"><img src="${pageContext.request.contextPath}/assets/img/logo-dark.png" alt="Klorofil Logo"></div>
                            <p class="lead">登录我的帐号</p>
                        </div>
                        <form class="form-auth-small" action="${pageContext.request.contextPath}/login" method="post">
                            <div class="form-group">
                                <label for="signin-user" class="control-label sr-only">User</label>
                                <input type="text" class="form-control" id="signin-user" name="signin-user" value="admin" placeholder="用户名">
                            </div>
                            <div class="form-group">
                                <label for="signin-password" class="control-label sr-only">Password</label>
                                <input type="password" class="form-control" id="signin-password" name="signin-password" value="123456" placeholder="密码">
                            </div>
                            <div class="form-group">
                                <label for="signin-captcha" class="control-label sr-only">Captcha</label>
                                <input type="text" class="form-control captcha" id="signin-captcha" name="signin-captcha" value="" placeholder="验证码">
                                <div class="captcha-box">
                                    <a href="javascript:void(0)" onclick="changeImg()">
                                        <img id="randCaptcha" class="captcha-img" src="${pageContext.request.contextPath}/getCaptcha" alt="验证码">
                                    </a>
                                </div>
                            </div>
                            <div class="form-group clearfix">
                                <label class="fancy-checkbox element-left">
                                    <input type="checkbox" name="license">
                                    <span>同意使用协议 <a href="http://apache.org/licenses/LICENSE-2.0.txt" target="_blank">Apache Software License 2.0</a></span>
                                </label>
                            </div>
                            <button type="submit" class="btn btn-primary btn-lg btn-block">登录</button>
                            <div class="bottom">
                                <span class="helper-text"><i class="fa fa-lock"></i> <a href="#">忘记密码?</a></span>
                            </div>
                        </form>
                    </div>
                </div>
                <div class="right">
                    <div class="overlay"></div>
                    <div class="content text">
                        <h1 class="heading">Jfinal-cms 后台管理系统</h1>
                        <p>by LeonXiao</p>
                    </div>
                </div>
                <div class="clearfix"></div>
            </div>
        </div>
    </div>
</div>
<!-- END WRAPPER -->

<script src="${pageContext.request.contextPath}/assets/components/jquery/jquery.min.js"></script>
<script>
    function changeImg(){
        $('#randCaptcha').attr("src",'${pageContext.request.contextPath}/getCaptcha?t='+Math.random());
    }
</script>
</body>

</html>